<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<h2>我的简历</h2>
		<div id="Alldiv">
			
			
		</div>
		<hr>
		<a href="#" onclick="addDiv()">添加简历</a>
		
	</body>
	<script type="text/javascript">
		function addDiv(){
			var getAllDiv=document.getElementById('Alldiv');
			var newDiv=document.createElement('div');
			newDiv.innerHTML=`<hr>
				公司名称:<input type="" name="" id="" value="" />
				职位:<input type="" name="" id="" value="" />
				<br>
				<br>
				任职经历:
				<br>
				<textarea cols="100" rows="8"></textarea>
				<a href="#" onclick="delDiv(event)">删除该简历</a>`;
				getAllDiv.appendChild(newDiv);
		}
		function delDiv(event){
			var getAllDiv=document.getElementById('Alldiv'); 
			console.log(event.target);
			var getF=event.target.parentElement;
			console.log(getF);
			getAllDiv.removeChild(getF);
		}
		onload=function (){
			addDiv();
		}
	</script>
</html>
